﻿@model XoohooViewModel
<!DOCTYPE html>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>@RenderSection("TitleContent")</title>
    @RenderSection("MetaKeywords", false)
    @RenderSection("MetaDescription", false)
    @{Html.RenderScriptTag("Scripts/jquery.min.js");}
    @{Html.RenderScriptTag("Scripts/jquery.unobtrusive-ajax.min.js");}
    @{ 
#if DEBUG 
        Html.RenderScriptTag("Scripts/jquery.validate.js");   
        Html.RenderScriptTag("Scripts/jquery.validate.unobtrusive.js");
#else
        Html.RenderScriptTag("Scripts/jquery.validate.min.js");
        Html.RenderScriptTag("Scripts/jquery.validate.unobtrusive.min.js");
#endif

        Html.RenderScriptTag("Scripts/jquery.validate.unobtrusive.extensions.js");
        Html.RenderScriptTag("Scripts/common.js");

        Html.RenderCssFile("Styles/Validator/validator.css");

        Html.RenderScriptTag("Scripts/jquery-ui.min.js");
        Html.RenderCssFile("Styles/JqueryUI/jquery-ui.css");
        Html.RenderCssFile("Styles/InnerPage.css");
    }
    <script language="javascript" type="text/javascript">
        $(document).ready(function () {
            var loading = $("#loading");
            loading.height($(document).height());
            loading.css("opacity", 0.5);
            loading.ajaxStart(function () {
                $(this).show();
            }).ajaxStop(function () {
                $(this).hide();
            });
            $('#dialog').dialog({
                autoOpen: false,
                modal: true,
                width: 280,
                buttons: {
                    "确定": function () {
                        $(this).dialog("close");
                    }
                }
            });
        });

        function ShowAlert(title, msg) {
            $("#dialog").dialog("option", "title", title);
            $("#dialog").html("<p>" + msg + "</p>");
            $('#dialog').dialog('open');
        }

        //$.ui.dialog.defaults.bgiframe = true;
    </script>
    @RenderSection("HeadCustom", false)
</head>
<body>
     <div class="nav">@RenderSection("NavigationContent", false)</div>
    @RenderBody()
    <div id="dialog">
    </div>
    <div id="loading">@Html.SkinImage("Styles/Images/loading.gif", "加载中...")</div>
</body>
</html>
